import App from './App'
import Vue from 'vue'
// request请求
import http from '@/common/service/service.js';
import {
	ACCESS_TOKEN
} from '@/common/util/constants.js'
import api from '@/api/api.js';
// 全局mixins，用于实现setData等功能';
import Mixin from './polyfill/mixins';

// 仅 web 有效
// import OSS from './aliyun-upload-sdk-1.5.4/lib/aliyun-oss-sdk-6.17.1.min'
// window.OSS = OSS;
// import './aliyun-upload-sdk-1.5.4/aliyun-upload-sdk-1.5.4.min'

Vue.mixin(Mixin);

Vue.config.productionTip = false
App.mpType = 'app'

import store from './store'
Vue.prototype.$store = store

Vue.prototype.$http = http;
Vue.prototype.$api = api;

Vue.prototype.$isLogin = () => {
	let token = uni.getStorageSync(ACCESS_TOKEN)
	if (token == null || token == "") {
		return false
	} else {
		return true
	}
}




const app = new Vue({
	store,
	...App
})
app.$mount()
